Total Complexity | 2 |
Total Lines | 22 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | import { |
||
6 | |||
7 | @Entity() |
||
8 | export class InterestRate { |
||
9 | @PrimaryGeneratedColumn('uuid') |
||
10 | private id: string; |
||
11 | |||
12 | @Column({ type: 'integer', nullable: false, comment: 'Stored in base 100' }) |
||
13 | private rate: number; |
||
14 | |||
15 | @Column({ type: 'timestamp', default: () => 'CURRENT_TIMESTAMP' }) |
||
16 | private createdAt: Date; |
||
17 | |||
18 | constructor(rate: number) { |
||
19 | this.rate = rate; |
||
20 | } |
||
21 | |||
22 | public getId(): string { |
||
23 | return this.id; |
||
24 | } |
||
25 | |||
26 | public getRate(): number { |
||
27 | return this.rate; |
||
28 | } |
||
30 |